package chapter_7;

import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.FileReader;
import java.io.FileWriter;

public class Test13 {
    public static void main(String[] args) throws Exception{
        FileWriter fw = new FileWriter("D:\\str.txt");
        BufferedWriter bw = new BufferedWriter(fw);
        bw.write("你好");
        bw.write(98);
        bw.newLine();
        bw.write("结束饿了");
        bw.close();

        FileReader fr = new FileReader("D:\\str.txt");
        BufferedReader br = new BufferedReader(fr);
        System.out.println(br.readLine());
        System.out.println(br.readLine());
        br.close();


    }
}
